package fti.uksw.ruang.model;

import android.os.Parcel;
import android.os.Parcelable;

public class Pengguna implements Parcelable {

	public final static String TAG = "pengguna";

	public final static String TABLEBNAME = "tbpengguna";
	public final static String ID = "id";
	public final static String NAMA = "nama";
	public final static String NOTELP = "no_telp";

	private int id;
	private String nama;
	private String noTelp;

	public Pengguna(){}
	
	public Pengguna(Parcel in){
		readFromParcel(in);
	}
	
	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public String getNama() {
		return nama;
	}

	public void setNama(String nama) {
		this.nama = nama;
	}

	public String getNoTelp() {
		return noTelp;
	}

	public void setNoTelp(String noTelp) {
		this.noTelp = noTelp;
	}

	@Override
	public int describeContents() {
		return 0;
	}

	@Override
	public void writeToParcel(Parcel dest, int flags) {
		dest.writeInt(id);
		dest.writeString(nama);
		dest.writeString(noTelp);
	}
	private void readFromParcel(Parcel in) {
		id = in.readInt();
		nama = in.readString();
		noTelp = in.readString();
	}

	public static final Parcelable.Creator<Pengguna> CREATOR = new Parcelable.Creator<Pengguna>() {

		@Override
		public Pengguna createFromParcel(Parcel source) {
			return new Pengguna(source);
		}

		@Override
		public Pengguna[] newArray(int size) {
			return new Pengguna[size];
		}
	};
}
